#include <bits/stdc++.h>

using namespace std;

typedef unsigned long long ULL;

ULL Base = 29;
const ULL Maxn = 1e6 + 10;

ULL hash1(string s)
{
    ULL p1[s.size() + 10],h1[s.size() + 10];
    p1[0] = 1;
    h1[0] = 0;
    for(int i = 1; i < s.size(); i ++)
    {
        h1[i] = (h1[i - 1] * Base + s[i] - 'a' + 1);
    }
    for(int i = 1; i < s.size(); i ++)
    {
        p1[i] = p1[i - 1] * Base;
    }
    ULL now_hash1 = (h1[s.size() - 1] - h1[0] * p1[s.size() + 1]);
    return now_hash1;
}

int main()
{
    int n;
    vector<int> ans;
    cin >> n;
    for(int i = 1; i <= n; i ++)
    {
        string s;
        cin >> s;
        s = ' ' + s;
        ans.push_back(hash1(s));
    }
    sort(ans.begin(),ans.end());
    int cnt = 0;
    for(int i = 1; i < ans.size(); i ++)
    {
        if(ans[i] != ans[i - 1])
        {
            cnt ++;
        }
    }
    cout << cnt + 1 << endl;
}